package com.aliang.shopping.model.po;

import com.baomidou.mybatisplus.annotation.*;
import lombok.Data;

import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;

/**
 * 评论表
 * @TableName comment
 */
@TableName(value ="comment")
@Data
public class Comment implements Serializable {
    /**
     * 数据Id
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 评论文本
     */
    @TableField(value = "comment_text")
    private String commentText;

    /**
     * 评论图片
     */
    @TableField(value = "comment_image")
    private String commentImage;

    /**
     * 点赞数
     */
    @TableField(value = "like_num")
    private Integer likeNum;

    /**
     * 评分
     */
    @TableField(value = "score_num")
    private BigDecimal scoreNum;

    /**
     * 评论人Id
     */
    @TableField(value = "user_id")
    private Long userId;

    /**
     * 订单Id
     */
    @TableField(value = "orders_id")
    private Long ordersId;

    /**
     * 评论状态，默认正常
     */
    @TableField(value = "status")
    private Integer status;

    /**
     * 评论时间
     */
    @TableField(value = "create_time", fill = FieldFill.INSERT)
    private LocalDateTime createTime;

    /**
     * 删除标志
     */
    @TableField(value = "is_delete")
    private Integer isDelete;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}